// 测试福利卡分页显示功能
console.log('测试福利卡分页显示功能');

// 模拟数据
const mockData = {
    cardListWithStatus: [
        { id: 1, name: '福利卡1', score: 100, isSelected: false, color_index: 0 },
        { id: 2, name: '福利卡2', score: 200, isSelected: false, color_index: 1 },
        { id: 3, name: '福利卡3', score: 150, isSelected: false, color_index: 2 },
        { id: 4, name: '福利卡4', score: 300, isSelected: false, color_index: 3 },
        { id: 5, name: '福利卡5', score: 250, isSelected: false, color_index: 4 }
    ],
    showAllCards: false,
    displayCardCount: 3
};

// 测试切换显示逻辑
function toggleShowAllCards() {
    mockData.showAllCards = !mockData.showAllCards;
    mockData.displayCardCount = mockData.showAllCards ? mockData.cardListWithStatus.length : 3;
    
    console.log('切换后状态:', {
        showAllCards: mockData.showAllCards,
        displayCardCount: mockData.displayCardCount,
        totalCards: mockData.cardListWithStatus.length
    });
}

// 测试初始状态
console.log('初始状态:', {
    showAllCards: mockData.showAllCards,
    displayCardCount: mockData.displayCardCount,
    totalCards: mockData.cardListWithStatus.length
});

// 测试展开
console.log('\n点击"更多"按钮:');
toggleShowAllCards();

// 测试收起
console.log('\n点击"收起"按钮:');
toggleShowAllCards();

console.log('\n测试完成！');
